home *** CD-ROM | disk | FTP | other *** search
/ MacAddict 117 / MacAddict 117.dmg / Software / Internet & Communication / Snak 5.1 (shareware).dmg / Snak.app / Contents / Resources / Scripts / basical.txt < prev    next >
Text File  |  2005-11-13  |  4KB  |  176 lines

  1. # This file is based on a file included with the standard distribution of ircII
  2. # It contains useful aliases for Snak. The aliases allows you to reduce the 
  3. # amount of typing. 
  4.  
  5. # basical and action are automatically loaded into each connection 
  6. # when the connection is opened
  7.  
  8. # Lines with '#' are comments that are not executed
  9.  
  10. # The format of a simple alias definition is simply the word "alias" followed by the name 
  11. # you give the new alias, and the actual contents of the alias.
  12.  
  13. # For more elaborate aliases, consisting of multiple lines of commands you need to put 
  14. # brackets around the commands like this:
  15.  
  16. # alias elaborateAlias {
  17. #     command1
  18. #     command 2
  19. # }
  20.  
  21. # See the oops alias in this file for an example of a multi line alias.
  22.  
  23. # To run the alias (and any other command) type /<name> and any necessary parameters 
  24. # and press enter in an input field. 
  25.  
  26.  
  27. alias F5 echo testing function keys
  28. alias F6 whois url
  29. alias Finger CTCP $0 FINGER
  30. alias Version CTCP $0 VERSION
  31. alias Time CTCP $0 TIME
  32. alias Userinfo CTCP $0 USERINFO
  33. alias Clientinfo CTCP $0 CLIENTINFO
  34. alias Chat DCC CHAT $0-
  35. alias DQuery DCC CHAT $0-
  36. alias tn mode $C +tn
  37. alias op mode $C +ooo
  38. alias deop mode $C -ooo
  39. alias ban mode $C +bbb
  40. alias ChannelClick query $E
  41. alias ConsoleClick msg $E $*
  42. alias sslserver server -ssl
  43.  
  44. alias m msg
  45. alias i invite $0 $C
  46. alias a away
  47. alias c channel
  48. alias ch channel
  49. alias e exit
  50. alias h help
  51. alias j join
  52. alias l list
  53. alias log set log
  54. alias n names
  55. alias s signoff
  56. alias t topic
  57. alias w whois
  58. alias q query
  59. alias play sound
  60.  
  61. alias chop mo +o
  62. alias unchop mo -o $*
  63. alias mo mode $C $*
  64. alias k kick $C
  65. alias wdetected whois $D
  66. alias umode mode $N
  67.  
  68. alias mr msg $, $*
  69. alias ma msg $. $*
  70. alias wa whois $.
  71. alias ia invite $. $C
  72.  
  73. alias no notice
  74. alias nf notify
  75. alias la lastlog
  76.  
  77. alias " quote
  78. alias unalias alias -$*
  79.  
  80.  
  81. alias shields_up ignore $, msgs notices
  82. alias protect mode $C +ni
  83. alias unprotect mode $C -ni
  84. alias chops who $C -chop
  85. alias wjoin j $0
  86. alias talkto query $0
  87.  
  88. alias oops {
  89.     ^assign alias.oops $B
  90.     msg $. Sorry, that wasn't meant for you.
  91.     msg $0 $alias.oops
  92. }
  93.  
  94. alias dmsg msg =$0 $1-
  95. alias dquery /query =$0
  96.  
  97. # Functions for server control.
  98. # They only work if you are a server operator.
  99.  
  100. alias wo wallops
  101. alias ow operwall
  102.  
  103.  
  104. # utility function that returns the nick part of a nick!userhost string
  105. alias nickonly {@ FUNCTION_RETURN = left($index(! $0) $0)}
  106.  
  107.  
  108. # This lets you assign aliases for peoples nicknames.
  109. # For example, of you do: /assign BC BigCheese
  110. # Then you can do: /amsg BC Hi there!
  111.  
  112. alias amsg {
  113.     if ( [$($0)] )
  114.     {
  115.         ${K}${K}msg $($0) $1-
  116.     }
  117.     {
  118.         ${K}${K}msg $0 $1-
  119.     }
  120. }
  121. alias aquery {
  122.     if ( [$($0)] )
  123.     {
  124.         ${K}${K}query $($0)
  125.     }
  126.     {
  127.         ${K}${K}query $0-
  128.     }
  129. }
  130.  
  131.  
  132. # The repeatcmd and listtest aliases show how you can repeat an action a number of times
  133.  
  134. # Use a simply while loop to repeat a command. 
  135. # $0 is the number of times to do something
  136. # $1 is the string with the action to perform
  137.  
  138. # Usage "/repeatcmd 5 echo Snak is a nice program"
  139. alias repeatcmd {
  140.     @ rep.cnt = [$0]
  141.     while ( rep.cnt > 0 )
  142.     {
  143.         $1-
  144.         @rep.cnt = rep.cnt - 1
  145.     }
  146.     ^assign -rep.cnt
  147. }
  148.     
  149. # This steps over all numbered items in the array and echoes their value 
  150.  
  151. alias listtest {
  152.     assign blue.1 one
  153.     assign blue.2 two 
  154.     assign blue.3 three
  155.     foreach blue ii { echo $ii $blue[$ii] }
  156. }
  157.  
  158. # The $me variable is a synonum for $N that holds your nick
  159. assign me $N
  160.  
  161. # these aliases illustrate how to use color in messages. In addition to $color(string), there is also $bold(), $italic(), $underline(), and $plain()
  162. alias BUY ME $color(9,3)----$color(0,3)buys $color(0,3) $0 $color(15,3) @ $color(0,3) $1-15$color(9,3)----
  163. alias SELL ME $color(12,2)----$color(0,2)sells $color(0,2)  $0 $color(15,2) @ $color(0,2) $1-15 $color(12,2)---
  164. alias SHORT ME $color(4,5)----$color(0,5)shorts $color(0,5) $0 $color(15,5) @ $color(0,5) $1-15 $color(4,5)---
  165. alias COVER ME $color(12,2)----$color(0,2)covers $color(0,2) $0 $color(15,2) @ $color(0,2) $1-15 $color(12,2)----
  166.  
  167. alias COLORTEST ME $color(12,2) COLOR $bold()BOLD COLOR $underline() UNDERLINE BOLD COLOR $plain() PLAIN $bold() PLAIN BOLD
  168.  
  169. # This snippet is an example of a hook for a numbered command. The server sends topic information in a 
  170. # numbered message 332. If the topic is not work safe or otherwise inappropriate you can
  171. # block the numbered message. This empty script will simply swallow it.
  172. #on ^332 * {
  173. #}
  174.  
  175.  
  176.